package com.mybatis.lo.sqlsource;

import com.mybatis.lo.mapping.BoundSql;
import com.mybatis.lo.sqlnode.SqlNode;

/**
 * 封装了没有`${}`和动态标签SQL的信息，且初始化后，每次重新获取只需要返回相同sql即可
 * @author zhangbh
 * 2023-06-09 20:09
 **/
public class RawSqlSource extends BaseSqlSource {


    private final BoundSql boundSql;

    public RawSqlSource(SqlNode mixedSqlNode) {
        boundSql = getBoundSql(null, mixedSqlNode);
    }

    @Override
    public BoundSql getBoundSql(Object param) {
        return boundSql;
    }
}
